from flask import Flask
from flask import url_for

app = Flask(__name__)

# 银行卡开户
@app.route('/add/<bankName>/')
def addCard(bankName):
    return "%s 开启成功!" % bankName

# 选择银行卡
@app.route('/select')
def selectBank():
    # 查询所有银行，供用户选择
    # 用户选择之后，进入开户页面
    bankName = "中国银行"
    next_url = "/add/" + bankName
    return """
    选择银行成功，3秒后<a href="%s">进入开户页面</a>
    """ % url_for(addCard,bankName)

app.run('localhost',5000)
